<template>
    <div class="sum">
        <van-nav-bar title="行业优选" left-arrow @click-left="onClickLeft" />
        <div class="imgs" v-if="bannerList">
            <div class="img" v-for="img in bannerList" :key="img.firstMiddleBanner.bannerVos[0].imagePath">
                <img :src="img.firstMiddleBanner.bannerVos[0].imagePath">
            </div>
        </div>
    </div>
</template>

<script>
export default {
    data() {
        return {
            bannerList: []
        }
    },
    created() {
        this.$apiProxy({
            url: "/marketing/v3/1063",
            method: "get"
        }).then(res => {
            this.bannerList = res.data.h5MarketFloorAllVos;
        })
    },
    methods: {
        onClickLeft() {
            this.$router.push({ name: "home" })
        },
    },
}
</script>

<style lang="less">
.sum {
    .van-nav-bar {
        position: fixed;
        left: 0;
        right: 0;
        top: 0;
    }

    .imgs {
        margin-top: 46px;
        background-color: #fff;
        padding-top: 12px;
        padding-bottom: 7.5px;

        .img {
            padding: 0 10px;
            margin-bottom: 15px;
        }
    }
}
</style>